package com.yunyao.dao.service.bamu;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yunyao.common.dto.order.ProjectOrderDto;
import com.yunyao.dao.model.BamuPurchaseApply;
import com.yunyao.dao.model.BamuSaleContract;
import com.yunyao.dao.model.BamuSpReconciliationOrder;
import org.apache.ibatis.annotations.Param;
import org.springframework.validation.annotation.Validated;

import javax.validation.constraints.NotBlank;
import java.math.BigDecimal;
import java.util.List;

/**
 * <p>
 * 合同材料表 服务类
 * </p>
 *
 * @author xingjishuai
 * @since 2024-07-02
 */
@Validated
public interface IBamuPurchaseApplyService extends IService<BamuPurchaseApply> {
    /**
     * 根据条件获取采购订单、项目订单列表
     */
    IPage<BamuPurchaseApply> getPurchaseApplyList(ProjectOrderDto projectOrderDto);

    BamuPurchaseApply getNoDeletedApplyById(String id);

//    BamuPurchaseApply getBySupplyApplyId(String id);

    List<BamuPurchaseApply> listByReconciliationSettlementIdDeleted(String contractId);


    BigDecimal getTotalPriceByContractId(String contractId);

    List<BamuPurchaseApply> listById(String Id);

    /**
     * 根据订单编号获取订单信息
     *
     * @param orderNo
     * @return
     */
    BamuPurchaseApply getOderId(@NotBlank String orderNo, @NotBlank String contractId);
}
